package cn.gzjp.modules.woms.service;

import java.util.List;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import cn.gzjp.common.persistence.Page;
import cn.gzjp.common.service.CrudService;
import cn.gzjp.modules.woms.entity.EventPic;
import cn.gzjp.modules.woms.dao.EventPicDao;

/**
 * 工单图片Service
 * @author liyp
 * @version 2018-07-12
 */
@Service
@Transactional(readOnly = true)
public class EventPicService extends CrudService<EventPicDao, EventPic> {

	public EventPic get(String id) {
		return super.get(id);
	}
	
	public List<EventPic> findList(EventPic eventPic) {
		return super.findList(eventPic);
	}

	public List<EventPic> findListByEventIdAndType(EventPic eventPic) {
		return dao.findListByEventIdAndType(eventPic);
	}

	public Page<EventPic> findPage(Page<EventPic> page, EventPic eventPic) {
		return super.findPage(page, eventPic);
	}
	
	@Transactional(readOnly = false)
	public void save(EventPic eventPic) {
		super.save(eventPic);
	}
	
	@Transactional(readOnly = false)
	public void delete(EventPic eventPic) {
		super.deleteByLogic(eventPic);
	}
	
}